<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.16"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>LibTools: CEvent类 参考</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">LibTools
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.8.16 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',false,false,'search.php','搜索');
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public 成员函数</a> &#124;
<a href="#pri-methods">Private 成员函数</a> &#124;
<a href="#pri-attribs">Private 属性</a> &#124;
<a href="class_c_event-members.html">所有成员列表</a>  </div>
  <div class="headertitle">
<div class="title">CEvent类 参考</div>  </div>
</div><!--header-->
<div class="contents">

<p>事件类  
 <a href="class_c_event.html#details">更多...</a></p>

<p><code>#include &lt;<a class="el" href="_event_8h_source.html">Event.h</a>&gt;</code></p>
<div class="dynheader">
类 CEvent 继承关系图:</div>
<div class="dyncontent">
 <div class="center">
  <img src="class_c_event.png" usemap="#CEvent_map" alt=""/>
  <map id="CEvent_map" name="CEvent_map">
<area href="class_c_event_base.html" title="事件处理基类" alt="CEventBase" shape="rect" coords="0,0,81,24"/>
  </map>
</div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public 成员函数</h2></td></tr>
<tr class="memitem:ae2c9888dbf2c9684be63500e25bae8df"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event.html#ae2c9888dbf2c9684be63500e25bae8df">CEvent</a> (bool status=false, bool reset=true)</td></tr>
<tr class="separator:ae2c9888dbf2c9684be63500e25bae8df"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad088f3ce4e9585ce8fadafb5655511fb"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event.html#ad088f3ce4e9585ce8fadafb5655511fb">~CEvent</a> ()</td></tr>
<tr class="separator:ad088f3ce4e9585ce8fadafb5655511fb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a72f175fe274eb8aa4b6f5c49c13a4a45"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="_wait_status_8h.html#aefc65d67c2144bee893b543992f694e2">wt_status</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event.html#a72f175fe274eb8aa4b6f5c49c13a4a45">Wait</a> (unsigned <a class="el" href="_find_file_8h.html#a37cc1038758216808d5f75090b093c9a">int</a> pred)</td></tr>
<tr class="memdesc:a72f175fe274eb8aa4b6f5c49c13a4a45"><td class="mdescLeft">&#160;</td><td class="mdescRight">等待事件有信号  <a href="class_c_event.html#a72f175fe274eb8aa4b6f5c49c13a4a45">更多...</a><br /></td></tr>
<tr class="separator:a72f175fe274eb8aa4b6f5c49c13a4a45"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a16992490c352dc9ad55430d5dc91698d"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="_wait_status_8h.html#aefc65d67c2144bee893b543992f694e2">wt_status</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event.html#a16992490c352dc9ad55430d5dc91698d">Wait_Forever</a> ()</td></tr>
<tr class="memdesc:a16992490c352dc9ad55430d5dc91698d"><td class="mdescLeft">&#160;</td><td class="mdescRight">一直等待事件，直到有信号时退出  <a href="class_c_event.html#a16992490c352dc9ad55430d5dc91698d">更多...</a><br /></td></tr>
<tr class="separator:a16992490c352dc9ad55430d5dc91698d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a19b3ef35c853d54d2debf57c9368ca3f"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event.html#a19b3ef35c853d54d2debf57c9368ca3f">SetEvent</a> (bool status)</td></tr>
<tr class="memdesc:a19b3ef35c853d54d2debf57c9368ca3f"><td class="mdescLeft">&#160;</td><td class="mdescRight">设置事件是否有信号  <a href="class_c_event.html#a19b3ef35c853d54d2debf57c9368ca3f">更多...</a><br /></td></tr>
<tr class="separator:a19b3ef35c853d54d2debf57c9368ca3f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0f46504df9e8a7c2c500209a15af0987"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="tools_8h.html#a01e895c2df346ffe662bbe69686d8d51">SYNCHANDLE</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event.html#a0f46504df9e8a7c2c500209a15af0987">Handle</a> () const</td></tr>
<tr class="memdesc:a0f46504df9e8a7c2c500209a15af0987"><td class="mdescLeft">&#160;</td><td class="mdescRight">返回事件句柄  <a href="class_c_event.html#a0f46504df9e8a7c2c500209a15af0987">更多...</a><br /></td></tr>
<tr class="separator:a0f46504df9e8a7c2c500209a15af0987"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="inherit_header pub_methods_class_c_event_base"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_class_c_event_base')"><img src="closed.png" alt="-"/>&#160;Public 成员函数 继承自 <a class="el" href="class_c_event_base.html">CEventBase</a></td></tr>
<tr class="memitem:ab875c6421774b41bd55c69212e06ae89 inherit pub_methods_class_c_event_base"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event_base.html#ab875c6421774b41bd55c69212e06ae89">CEventBase</a> (bool status=false, bool reset=true)</td></tr>
<tr class="memdesc:ab875c6421774b41bd55c69212e06ae89 inherit pub_methods_class_c_event_base"><td class="mdescLeft">&#160;</td><td class="mdescRight">初始化创建一个事件  <a href="class_c_event_base.html#ab875c6421774b41bd55c69212e06ae89">更多...</a><br /></td></tr>
<tr class="separator:ab875c6421774b41bd55c69212e06ae89 inherit pub_methods_class_c_event_base"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aba686a47a406e6b8c164220c98b814ef inherit pub_methods_class_c_event_base"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event_base.html#aba686a47a406e6b8c164220c98b814ef">~CEventBase</a> ()</td></tr>
<tr class="separator:aba686a47a406e6b8c164220c98b814ef inherit pub_methods_class_c_event_base"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-methods"></a>
Private 成员函数</h2></td></tr>
<tr class="memitem:a9de7ff9d2be49bf9e24e8bfb0a661be7"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event.html#a9de7ff9d2be49bf9e24e8bfb0a661be7">delete_class_copy_operator</a> (<a class="el" href="class_c_event.html">CEvent</a>)</td></tr>
<tr class="separator:a9de7ff9d2be49bf9e24e8bfb0a661be7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-attribs"></a>
Private 属性</h2></td></tr>
<tr class="memitem:a8d111caf7221ea4c35980af8bae632c4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="tools_8h.html#a01e895c2df346ffe662bbe69686d8d51">SYNCHANDLE</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_event.html#a8d111caf7221ea4c35980af8bae632c4">_event</a></td></tr>
<tr class="separator:a8d111caf7221ea4c35980af8bae632c4"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">详细描述</h2>
<div class="textblock"><p>事件类 </p>

<p class="definition">在文件 <a class="el" href="_event_8h_source.html">Event.h</a> 第 <a class="el" href="_event_8h_source.html#l00047">47</a> 行定义.</p>
</div><h2 class="groupheader">构造及析构函数说明</h2>
<a id="ae2c9888dbf2c9684be63500e25bae8df"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae2c9888dbf2c9684be63500e25bae8df">&#9670;&nbsp;</a></span>CEvent()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="tools_8h.html#a201ce692c9dca6599e5c12d00167419b">DEF_BEG_LIBTOOLS</a> CEvent::CEvent </td>
          <td>(</td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>status</em> = <code>false</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>reset</em> = <code>true</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p class="definition">在文件 <a class="el" href="_event_8cpp_source.html">Event.cpp</a> 第 <a class="el" href="_event_8cpp_source.html#l00007">7</a> 行定义.</p>

</div>
</div>
<a id="ad088f3ce4e9585ce8fadafb5655511fb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad088f3ce4e9585ce8fadafb5655511fb">&#9670;&nbsp;</a></span>~CEvent()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">CEvent::~CEvent </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p class="definition">在文件 <a class="el" href="_event_8cpp_source.html">Event.cpp</a> 第 <a class="el" href="_event_8cpp_source.html#l00013">13</a> 行定义.</p>

</div>
</div>
<h2 class="groupheader">成员函数说明</h2>
<a id="a9de7ff9d2be49bf9e24e8bfb0a661be7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9de7ff9d2be49bf9e24e8bfb0a661be7">&#9670;&nbsp;</a></span>delete_class_copy_operator()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">CEvent::delete_class_copy_operator </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="class_c_event.html">CEvent</a>&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="a0f46504df9e8a7c2c500209a15af0987"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0f46504df9e8a7c2c500209a15af0987">&#9670;&nbsp;</a></span>Handle()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="tools_8h.html#a01e895c2df346ffe662bbe69686d8d51">SYNCHANDLE</a> CEvent::Handle </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>返回事件句柄 </p>

<p>实现了 <a class="el" href="class_c_event_base.html#acc35df69c7c84c210f845976b4f060f1">CEventBase</a>.</p>

<p class="definition">在文件 <a class="el" href="_event_8cpp_source.html">Event.cpp</a> 第 <a class="el" href="_event_8cpp_source.html#l00046">46</a> 行定义.</p>

</div>
</div>
<a id="a19b3ef35c853d54d2debf57c9368ca3f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a19b3ef35c853d54d2debf57c9368ca3f">&#9670;&nbsp;</a></span>SetEvent()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void CEvent::SetEvent </td>
          <td>(</td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>status</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>设置事件是否有信号 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">status</td><td>若为true则有信号，false则无信号 </td></tr>
  </table>
  </dd>
</dl>

<p>实现了 <a class="el" href="class_c_event_base.html#a0c53f1d6c89e9a6cf4f0b168f2565e23">CEventBase</a>.</p>

<p class="definition">在文件 <a class="el" href="_event_8cpp_source.html">Event.cpp</a> 第 <a class="el" href="_event_8cpp_source.html#l00019">19</a> 行定义.</p>

</div>
</div>
<a id="a72f175fe274eb8aa4b6f5c49c13a4a45"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a72f175fe274eb8aa4b6f5c49c13a4a45">&#9670;&nbsp;</a></span>Wait()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_wait_status_8h.html#aefc65d67c2144bee893b543992f694e2">wt_status</a> CEvent::Wait </td>
          <td>(</td>
          <td class="paramtype">unsigned <a class="el" href="_find_file_8h.html#a37cc1038758216808d5f75090b093c9a">int</a>&#160;</td>
          <td class="paramname"><em>pred</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>等待事件有信号 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">pred</td><td>等待时长，单位毫秒 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>成功返回true,失败返回false </dd></dl>

<p>实现了 <a class="el" href="class_c_event_base.html#a34f33f39578574417d5dfa174faa921d">CEventBase</a>.</p>

<p class="definition">在文件 <a class="el" href="_event_8cpp_source.html">Event.cpp</a> 第 <a class="el" href="_event_8cpp_source.html#l00024">24</a> 行定义.</p>

</div>
</div>
<a id="a16992490c352dc9ad55430d5dc91698d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a16992490c352dc9ad55430d5dc91698d">&#9670;&nbsp;</a></span>Wait_Forever()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="_wait_status_8h.html#aefc65d67c2144bee893b543992f694e2">wt_status</a> CEvent::Wait_Forever </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>一直等待事件，直到有信号时退出 </p>

<p>实现了 <a class="el" href="class_c_event_base.html#abe9657c5257a91dfb4b2bf73e13a9a07">CEventBase</a>.</p>

<p class="definition">在文件 <a class="el" href="_event_8cpp_source.html">Event.cpp</a> 第 <a class="el" href="_event_8cpp_source.html#l00035">35</a> 行定义.</p>

</div>
</div>
<h2 class="groupheader">类成员变量说明</h2>
<a id="a8d111caf7221ea4c35980af8bae632c4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8d111caf7221ea4c35980af8bae632c4">&#9670;&nbsp;</a></span>_event</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="tools_8h.html#a01e895c2df346ffe662bbe69686d8d51">SYNCHANDLE</a> CEvent::_event</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p class="definition">在文件 <a class="el" href="_event_8h_source.html">Event.h</a> 第 <a class="el" href="_event_8h_source.html#l00077">77</a> 行定义.</p>

</div>
</div>
<hr/>该类的文档由以下文件生成:<ul>
<li>H:/project/LibTools/src/thread/<a class="el" href="_event_8h_source.html">Event.h</a></li>
<li>H:/project/LibTools/src/thread/<a class="el" href="_event_8cpp_source.html">Event.cpp</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
制作者 &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.16
</small></address>
</body>
</html>
